/*
 *   项目需求公共变量
 *
 * 备注：成员可以添加公共变量，添加后请做两件事：
 *      1.为你的变量添加注释，并取一个有语义的名称
 *      2.将新增的变量发送到群里，告知全体成员！【重要】
 *
 */
const VAR = {
	/* 送货信息对象数组 */
	// @isDelay：是否已延迟
	// @isDeliver：是否已交付
	// @Status：任务状态（0-待提货，1在途，2已完成）
	// carNumber车牌号
	deliveryInfoArray: [
		{
			id: 0,
			contactPerson: "张三",
			taskNumber: "XABB1234567",
			phone: "13800138000",
			pickupTime: "2022.01.01 10:00",
			estimatedDeliveryTime: "2022.01.01 12:00",
			actualAddress: "北京市朝阳区光华路 1 号 123 室",
			deliveryAddress: "北京市朝阳区光华路 1 号 123 室",
			isDelay: false,
			Status: 0,
			carNumber: "浙A999999",
			isDeliver: false
		},
		{
			id: 1,
			contactPerson: "李四",
			taskNumber: "XAHH6451829",
			phone: "13900139000",
			pickupTime: "2022.01.02 09:00",
			estimatedDeliveryTime: "2022.01.02 17:00",
			actualAddress: "上海市浦东新区世纪大道 2 号 303 室",
			deliveryAddress: "上海市浦东新区世纪大道 2 号 303 室",
			isDelay: false,
			Status: 0,
			carNumber: "浙A999999",
			isDeliver: false
		},
		{
			id: 2,
			contactPerson: "王五",
			taskNumber: "XAYY4346925",
			phone: "13700137000",
			pickupTime: "2022.01.03 11:00",
			estimatedDeliveryTime: "2022.01.03 19:00",
			actualAddress: "广州市天河区中山大道 123 号 404 室",
			deliveryAddress: "广州市天河区中山大道 123 号 404 室",
			isDelay: true,
			Status: 0,
			carNumber: "浙A999999",
			isDeliver: false
		},
		{
			id: 3,
			contactPerson: "赵六",
			taskNumber: "XALL8659543",
			phone: "13600136000",
			pickupTime: "2022.01.04 10:30",
			estimatedDeliveryTime: "2022.01.04 13:00",
			actualAddress: "深圳市南山区科技中一路 1 号 505 室",
			deliveryAddress: "深圳市南山区科技中一路 1 号 505 室",
			isDelay: false,
			Status: 0,
			carNumber: "浙A999999",
			isDeliver: false
		},
		{
			id: 4,
			contactPerson: "孙七",
			taskNumber: "XASS5623189",
			phone: "13500135000",
			pickupTime: "2022.01.05 12:00",
			estimatedDeliveryTime: "2022.01.05 16:00",
			actualAddress: "杭州市西湖区文三路 1 号 606 室",
			deliveryAddress: "杭州市西湖区文三路 1 号 606 室",
			isDelay: false,
			Status: 1,
			carNumber: "浙A999999",
			isDeliver: false
		},
		{
			id: 5,
			contactPerson: "周八",
			taskNumber: "XAGG9816452",
			phone: "13400134000",
			pickupTime: "2022.01.06 14:30",
			estimatedDeliveryTime: "2022.01.06 18:00",
			actualAddress: "成都市青羊区人民南路 1 号 707 室",
			deliveryAddress: "成都市青羊区人民南路 1 号 707 室",
			isDelay: false,
			Status: 0,
			carNumber: "浙A999999",
			isDeliver: false
		},
		{
			id: 6,
			contactPerson: "吴九",
			taskNumber: "XAMM1698457",
			phone: "13300133000",
			pickupTime: "2022.01.07 13:00",
			estimatedDeliveryTime: "2022.01.07 17:00",
			actualAddress: "重庆市江北区建新东路 2 号 808 室",
			deliveryAddress: "重庆市江北区建新东路 2 号 808 室",
			isDelay: false,
			Status: 1,
			carNumber: "浙A999999",
			isDeliver: false
		},
		{
			id: 7,
			contactPerson: "郑十",
			taskNumber: "XAQQ5326481",
			phone: "13200132000",
			pickupTime: "2022.01.08 11:30",
			estimatedDeliveryTime: "2022.01.08 16:00",
			actualAddress: "天津市滨海新区第一大街 3 号 909 室",
			deliveryAddress: "天津市滨海新区第一大街 3 号 909 室",
			isDelay: true,
			Status: 2,
			carNumber: "浙A999999",
			isDeliver: false
		},
		{
			id: 8,
			contactPerson: "冯十一",
			taskNumber: "XAPP9564812",
			phone: "13100131000",
			pickupTime: "2022.01.09 14:00",
			estimatedDeliveryTime: "2022.01.09 18:00",
			actualAddress: "上海市宝山区共和新路 1 号 1009 室",
			deliveryAddress: "上海市宝山区共和新路 1 号 1009 ",
			isDelay: false,
			Status: 1,
			carNumber: "浙A999999",
			isDeliver: false
		}
	],
	getProvince: function (str = "") {
		const Province = str.replace(
			/^浙江省|上海市|北京市|天津市|重庆市|黑龙江省|吉林省|辽宁省|内蒙古自治区|河北省|新疆维吾尔自治区|甘肃省|青海省|陕西省|宁夏回族自治区|河南省|山东省|山西省|安徽省|湖北省|湖南省|江苏省|四川省|贵州省|云南省|广西壮族自治区|西藏自治区|江西省|广东省|福建省|台湾省|海南省|香港特别行政区|澳门特别行政区$/,
			""
		)
		const market = Province.replace(/^.+市/, "")
		return [str.replace(Province, ""), Province.replace(market, ""), market]
	}
}
export { VAR }
